﻿using SharpGraphT.Graph;

namespace SharpGraphT.Util;

public class SupplierUtil {
    public static readonly Func<DefaultEdge> DefaultEdgeSupplier =
        () => new DefaultEdge();

    public static Func<T> CreateSupplier<T>() where T : class, new() =>
        () => new T();

    public static Func<string> CreateStringSupplier(int start) {
        var container = new[] { start };
        return () => container[0]++.ToString();
    }
}